using UnityEngine;
using System;
using System.Collections;

public class LevelText : MonoBehaviour {
	
	void Start()
	{
		transform.renderer.material.color = Color.black;
		string fatherLevel =  Convert.ToString(transform.parent.GetComponent<Level>().indexPhase);
		
		if (fatherLevel.Length < 2)
			fatherLevel = "0" + fatherLevel;
		
		GetComponent<TextMesh>().text = fatherLevel;
	}
}
